"""
家具 PO
"""

import utils.enum_utils as enum
from models import POBase
from models.other import (
    Dimensions,
    Vector3D,
)
from my_typing import *
from utils.data_utils.special import ObjectIdStr
from utils.validator_utils.pydantic_validator.field import (
    CharField,
    NormalField,
)


class FamilyFurniturePO(POBase):
    """ 家具 | PO """

    alias: StrOrNone = CharField(None, title="别名", min_length=3, max_length=32)
    description: StrOrNone = CharField(None, title="描述", min_length=1, max_length=200)
    dimensions: Dimensions | None = NormalField(..., description="家具的尺寸（长宽高）")
    name: str = CharField(..., title="名称", min_length=1, max_length=32)
    position_2_room: Vector3D | None = NormalField(None, title="位置（对于房间来说）")
    room_id: ObjectIdStr = CharField(..., title="房间 ID")
    type: enum.FurnitureType = NormalField(..., title="家具类型")
    user_id: ObjectIdStr = NormalField(..., title="用户 ID")
